<?php
class CommentController extends AppController {

	var $name = 'Comment';
	var $uses= array('Category','Company');
	// menu chinh	
	function menuTop(){
		$lang=$this->Session->read('lag');
		return $this->Category->find('all',array('conditions'=>array('Category.status'=>1,'Category.parent_id '=>NULL,'Category.lang_id'=>$lang,'Category.type'=>1)));	
	}
	function subTop(){
		$lang=$this->Session->read('lag');
		return $this->Category->find('all',array('conditions'=>array('Category.status'=>1,'Category.parent_id <>'=>NULL,'Category.lang_id'=>$lang,'Category.type'=>1)));	
	}
	//menu trai san pham
	function subMenuProduct(){
		$lang=$this->Session->read('lag');
		return $this->Category->find('all',array('conditions'=>array('Category.status'=>1,'Category.parent_id <>'=>NULL,'Category.lang_id'=>$lang,'Category.type'=>1)));	
	}
	//footer
	function showFooter(){
		$lang=$this->Session->read('lag');
		return $this->Company->find('all',array('conditions'=>array('Company.lang_id'=>$lang)));	
	
	}
}
	

?>
